<{include file="public/header.html"}>
		<div class="xinsu-right">
			<div class="xinsu-right-content">
				<div class="xinsu-data-content">
					<div class="xinsu-title">
						<span class="layui-breadcrumb">
							<a><cite>当前位置</cite></a>
							<a><cite>盈亏排序</cite></a>
						</span>
					</div>
					<form class="layui-form xinsu-form" action="" method="get">
						<div class="layui-form-item">
							<div class="layui-inline">
								<label class="layui-form-label xinsu-form-label">盈亏排序</label>
								<div class="layui-input-inline xinsu-input-inline">
									<select name="sort">
										<option value="0">总盈亏</option>
										<option value="1" <{if $sort == 1}>selected<{/if}>>周盈亏</option>
										<option value="2" <{if $sort == 2}>selected<{/if}>>日盈亏</option>
									</select>
								</div>
							</div>
						   <button class="layui-btn xinsu-btn">查询</button>
							<span>记录总数：共 <{$total}> 条</span>
						</div>
					</form>
					<div class="layui-form xinsu-form">
						<table class="layui-table">
							<thead>
								<tr>
									<th>代理商</th>
									<th>用户名</th>
									<th>真实姓名</th>
									<th>盈亏总和</th>
								</tr> 
							</thead>
							<tbody>
								<{if empty($list) == false}>
								<{foreach $list as $val}>
								<tr>
									<td><{$val.agent_name}></td>
									<td><a class="xinsu-fontcolor-blue xinsu-user" href="javascript:;" data="<{$val.uid}>"><{$val.username}></a></td>
									<td><{$val.realname}></td>
									<{if $val.total_gain > 0}>
									<td class="xinsu-fontcolor-red">￥<{number_format($val.total_gain, 2)}></td>
									<{else}>
									<td class="xinsu-fontcolor-green">￥<{number_format($val.total_gain, 2)}></td>
									<{/if}>
								</tr>
								<{/foreach}>
								<{else}>
								<tr>
									<td colspan="4">暂无数据</td>
								</tr>
								<{/if}>
							</tbody>
						</table>
					</div>
					<div class="xinsu-page">
						<div class="xinsu-show">
							<{$page}>
						</div>
						<div class="xinsu-clear"></div>
					</div>
				</div>
			</div>
		</div>
<{include file="public/footer.html"}>
